.ClipModal-component {
  font-family: AlimamaAgileVF-Thin;
  input {
    font-family: AlimamaAgileVF-Thin;
  }
  .ClipModal {
    width: 450px;
    height: fit-content;

    // background-color: #382847;
    background-color: #e8e8e8;
    border-radius: 5px;
    border: 1px solid rgb(125, 125, 125);
    position: fixed;
    top: 50%;
    left: 50%;
    opacity: 0;
    transition: 0.3s;
    pointer-events: none;
    z-index: 6;
    padding: 0 10px;
    padding-bottom: 10px;
    transform: translate(-50%, -50%) scale(0.9);

    &.show {
      opacity: 1;
      pointer-events: auto;
      transform: translate(-50%, -50%) scale(1);
    }
    .top {
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;
      color: #565656;
      height: 45px;
      .title {
        font-size: 15px;
      }

      .remove {
        background-color: var(--primary-color);
        width: auto;
        margin: 0;
        padding: 0;
        width: 30px;
        height: 30px;
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
        svg {
          fill: #fff;
        }
      }
    }
    .center-box {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 10px;
    }
    .canvas-view {
      width: 70%;
      aspect-ratio: 1;
      display: flex;
      position: relative;
    }
    .canvas {
      min-width: 160px;
      max-width: 300px;
      max-height: 300px;
      border: 1px solid #999;
      image-rendering: pixelated;
      user-select: none;
      box-sizing: content-box;
      // margin: auto;
      position: absolute;
      transform: translate(-50%, -50%);
      left: 50%;
      top: 50%;
    }
    .clip-box {
      position: absolute;
      left: 50%;
      top: 50%;
      transform: translate(-50%, -50%);
      // overflow: hidden;
      .clip-view {
        position: absolute;
        background-color: var(--hover-color);
        border: 1px solid var(--hover-color);
        cursor: grab;
        --point-size: 8px;
        .left,
        .top,
        .right,
        .bottom {
          position: absolute;
          background-color: var(--primary-color);
        }
        .left {
          left: 0;
          top: 0;
          width: 1px;
          height: 100%;
          cursor: e-resize;
        }
        .right {
          right: 0;
          top: 0;
          width: 1px;
          height: 100%;
          cursor: e-resize;
        }
        .top {
          left: 0;
          top: 0;
          width: 100%;
          height: 1px;
          cursor: n-resize;
        }
        .bottom {
          left: 0;
          bottom: 0;
          width: 100%;
          height: 1px;
          cursor: n-resize;
        }
        .cenlin {
          position: absolute;
          right: 50%;
          top: 0;
          width: 1px;
          border-left: 1px dashed var(--primary-color);
          height: 100%;
        }
        .leftTop,
        .rightTop,
        .rightBottom,
        .leftBottom {
          width: var(--point-size);
          height: var(--point-size);
          position: absolute;
          background-color: var(--primary-color);
          border-radius: 3px;
        }
        .leftTop {
          left: calc(var(--point-size) / -2);
          top: calc(var(--point-size) / -2);
          cursor: nw-resize;
        }
        .rightTop {
          right: calc(var(--point-size) / -2);
          top: calc(var(--point-size) / -2);
          cursor: ne-resize;
        }
        .rightBottom {
          right: calc(var(--point-size) / -2);
          bottom: calc(var(--point-size) / -2);
          cursor: nw-resize;
        }
        .leftBottom {
          left: calc(var(--point-size) / -2);
          bottom: calc(var(--point-size) / -2);
          cursor: ne-resize;
        }
      }
    }
    .input-box {
      display: flex;
      align-items: center;
      width: fit-content;
      gap: 5px;
      width: 95%;
      .label {
        width: 100px;
        text-align: right;
        font-size: 13px;
        &::after {
          content: ':';
        }
      }
      .color-input {
        height: 25px;
        width: 75px;
      }
      .input {
        background-color: white;
        border: 1px solid #ccc;
        outline: none;
        height: 30px;
        padding: 0 5px;
        width: 100px;
        text-align: center;
        border-radius: 5px;
      }
    }
  }
  .mask {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 5;
    opacity: 0;
    pointer-events: none;
    &.show {
      opacity: 1;
      pointer-events: auto;
    }
  }
}
